﻿<!doctype html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport"
          content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Todo List</title>
    <script src="https://code.jquery.com/jquery-3.6.0.min.js"></script>
    <link rel="stylesheet" href="/assets/styles.css" type="text/css">
    <script src="/assets/todo-list.js"></script>
</head>
<body>
<div>
    <form action="">
        <input type="text" name="item" placeholder="Add new todo" required />
        <button type="submit">Add</button>
    </form>
    <ul>
        <% for(var i = 0;i < todos.length;i++) { %>
            <li> <%= todos[i].item %> </li>
        <% } %>
    </ul>
</div>
</body>
</html>